<script>
	export default {
		onLaunch: function() {
			console.log('App Launch')
		},
		onShow: function() {
			console.log('App Show')

			let token = uni.getStorageSync('token');
			if (!uni.$u.test.isEmpty(token)) {
				this.$store.commit('user/saveToken', token);
			}

			let userInfo = uni.getStorageSync('userInfo');
			if (!uni.$u.test.isEmpty(userInfo)) {
				this.$store.commit('user/saveUserInfo', userInfo);
			}

		},
		onHide: function() {
			console.log('App Hide')
		}
	}
</script>

<style lang="scss">
/*每个页面公共css */
@import "@/uni_modules/uview-ui/index.scss";
@import "@/styles/global.scss";
</style>
